package com.asm.shiroweb.controller;

import org.apache.shiro.authz.annotation.RequiresAuthentication;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/salary")
public class SalaryController {

    @RequiresPermissions("salary")
    @RequiresAuthentication
    @RequestMapping("/query")
    public String query(){
        return "salary";
    }


    //    @RequiresUser
    @RequestMapping("/user")
    public Object testRedis1()
    {
        return "只需要user权限访问 --- user";
    }



}
